package org.lvslb.db.pojo;

import javax.persistence.Entity;
import javax.persistence.GeneratedValue;
import javax.persistence.Id;
import java.sql.Date;

/**
 * Created by MelOnDev1 on 14/05/14.
 */
@Entity
public class Admin {

    // Persistent Fields:
    @Id
    Long id;
    private String userName;
    private String userPwd;
    private Date signingDate;

    // Constructors:
    public Admin() {
    }

    public Admin(Long id ,String userName,String userPwd) {
        this.id = id;
        this.userName = userName;
        this.userPwd = userPwd;
    }


    public Long getId() {
        return id;
    }

    public void setId(Long id) {
        this.id = id;
    }

    public String getUserName() {
        return userName;
    }

    public void setUserName(String userName) {
        this.userName = userName;
    }

    public String getUserPwd() {
        return userPwd;
    }

    public void setUserPwd(String userPwd) {
        this.userPwd = userPwd;
    }

    public Date getSigningDate() {
        return signingDate;
    }

    public void setSigningDate(Date signingDate) {
        this.signingDate = signingDate;
    }



    // String Representation:
    @Override
    public String toString() {
        return userName + " (signed on " + signingDate + ")";
    }
}
